class BootStrap {

     def init = { servletContext ->
     	// Create some test data

 //	   def grailsEnv = System.getProperty("grails.env")
//	   if(grailsEnv == "development") {
     		
     		Date date = new Date()
            GregorianCalendar calendar = new GregorianCalendar()
            calendar.time = date
       		def grailsEnv = System.getProperty("grails.env")
   
 			def u1 = new User(login:"andersoooon", name: "Anderson", email:"anderson.ledo@gmail.com", password:"123456".encodeAsPassword())
            def u2 = new User(login:"victor", name: "Victor", email:"worshiper777@gmail.com", password:"123456".encodeAsPassword())
            def u3 = new User(login:"glauber", name: "Glauber", email:"anderson.ledo@gmail.com", password:"123456".encodeAsPassword())
     		u1.save()
     		u2.save()
     		u3.save()	
     		
    		new Device(model:"N800",manufactor:"descricao").save()
    		
//		} //if
    	
     }// def init
     
     def destroy = {
     }
} 